package com.oracle.scjp.sample.test;

public class LabelAbuse {

	public static void main(String[] args) {
		int x = 5;
		label1:
		while (x < 10) {
			x++;
		}
		if (true) {
			label2:
			for (int i = 0; i < 5; i++) {
				if (i == 4) {
					System.out.println("break label1;");
//					break label1; // "label1 is missing" compiler error
				}
				if (i == 3) {
					System.out.println("break label2;");
					break label2;
				}
			}
		}
		System.out.println("OH YEAH! :) ");
	}
	
}
